﻿{extend name="public:base" /}

{block name="css"}
<link rel="stylesheet" type="text/css" href="/static/layui/css/layui.css"/>
<link rel="stylesheet" type="text/css" href="__ADMIN__/css/style.css">
{/block}

{block name="content"}

<div class="wrapper wrapper-content animated fadeInRight">
    <div class="row">
        <div class="col-lg-12">
            <div class="ibox ">
                <div class="ibox-content">
                    <form method="post">
                        <div class="box-item">
                            <div class="form-group row">
                                <label class="col-sm-1 col-form-label">名称</label>
                                <div class="col-sm-3">
                                    <input type="text" class="form-control" name="name" placeholder="请输入名称" value="{$info.name}">
                                </div>
                            </div>
                            <div class="hr-line-dashed"></div>
                        </div>

                        <div class="box-item">
                            <div class="form-group row">
                                <label class="col-sm-1 col-form-label">描述</label>
                                <div class="col-sm-3">
                                    <input type="text" class="form-control" name="desc" placeholder="请输入描述" value="{$info.desc}">
                                </div>
                            </div>
                            <div class="hr-line-dashed"></div>
                        </div>

                        <div class="box-item">
                            <div class="form-group row layui-form">
                                <label class="col-sm-1 col-form-label">所属类目</label>
                                <div class="col-sm-3">
                                    <select name="type_id">
                                        <option value="0">请选择</option>
                                        {volist name="service_type_list" id="vo"}
                                        <option value="{$vo.id}" {$vo.id == $info.type_id ? 'selected' : ''}>{$vo.name}</option>
                                        {/volist}
                                    </select>
                                </div>
                            </div>
                            <div class="hr-line-dashed"></div>
                        </div>

                        <div class="box-item">
                            <div class="form-group row">
                                <label class="col-sm-1 col-form-label">真实服务人数</label>
                                <div class="col-sm-3">
                                    <input type="number" class="form-control" name="count" value="{$info.count}" readonly>
                                </div>
                            </div>
                            <div class="hr-line-dashed"></div>
                        </div>

                        <div class="box-item">
                            <div class="form-group row">
                                <label class="col-sm-1 col-form-label">虚拟服务人数</label>
                                <div class="col-sm-3">
                                    <input type="number" class="form-control" name="virtual_count" placeholder="请输入虚拟服务人数" value="{$info.virtual_count}">
                                </div>
                            </div>
                            <div class="hr-line-dashed"></div>
                        </div>

                        <div class="box-item">
                            <div class="form-group row">
                                <label class="col-sm-1 col-form-label">排序</label>
                                <div class="col-sm-3">
                                    <input type="number" class="form-control" name="sort" placeholder="请输入排序，数值越小，排序越靠前" value="{$info.sort}">
                                </div>
                            </div>
                            <div class="hr-line-dashed"></div>
                        </div>

                        <div class="box-item">
                            <div class="form-group row layui-form">
                                <label class="col-lg-1 col-form-label">状态</label>
                                <div class="col-lg-3">
                                    <input type="radio" name="status" value="1" title="上架" {$info.status!=2?'checked':''}>
                                    <input type="radio" name="status" value="2" title="下架" {$info.status==2?'checked':''}>
                                </div>
                            </div>
                            <div class="hr-line-dashed"></div>
                        </div>

                        <div class="box-item">
                            <div class="row">
                                <label class="col-sm-1 col-form-label">用户须知</label>
                                <div class="col-lg-6">
                                    <div class="ibox ">
                                        <textarea id="editor_id">{$info.know}</textarea>
                                        <textarea name="know" data-editor="kindEditor" style="display: none"></textarea>
                                    </div>
                                </div>
                            </div>

                            <div class="hr-line-dashed"></div>
                        </div>

                        <div class="box-item">
                            <div class="row">
                                <label class="col-sm-1 col-form-label">详情介绍</label>
                                <div class="col-lg-6">
                                    <div class="ibox ">
                                        <textarea id="editor_id2">{$info.content}</textarea>
                                        <textarea name="content" data-editor="kindEditor" style="display: none"></textarea>
                                    </div>
                                </div>
                            </div>

                            <div class="hr-line-dashed"></div>
                        </div>

                        <div class="form-group row">
                            <div class="col-sm-4 col-sm-offset-2">
                                <button type="button" class="btn btn-w-m btn-default back-page">返回</button>
                                <button type="button" class="btn btn-w-m btn-primary ajax-post">提交</button>
                            </div>
                        </div>
                    </form>
                </div>
            </div>
        </div>
    </div>
</div>

{include file="public/cropper-img-mask" cropper_uploaded_img_ids="cropper_uploaded_img_ids" cropper_uploaded_img_paths="cropper_uploaded_img_paths" crop_preview_box="crop-preview-box" /}{include file="public/preview-img-mask" swiper-id="cropper-preview" /}{/block}

{block name='js'}
<script src="__STATIC__/layui/layui.js"></script>
<script type="text/javascript" src="__PLUG__/kindeditor/kindeditor-all.js"></script>
<script>
    <!-- 实例化编辑器 -->
    initKindEditor('editor_id', 'know');
    initKindEditor('editor_id2', 'content');
</script>
{/block}